<!DOCTYPE html>

<head>
	<link rel="shortcut icon" href="data/favicon.png" />

	<meta charset="utf-8">

	<!-- Embed -->
	<title>创世声望树 - The Prestreestuck</title>
	<meta name="description" content="When you try to mix Homestuck with The Prestige Tree together. 18 layers and very huge numbers. I'm starting to regret making this.">

	<meta property="og:type" content="website" />
	<meta property="og:image" content="main-icon.png" />
	<meta property="og:description" content="When you try to mix Homestuck with The Prestige Tree together. 18 layers and very huge numbers. I'm starting to regret making this." />
	
	<meta name="twitter:card" content="summary" />
	<meta name="twitter:image" content="data/main-icon.png" />
	<meta name="twitter:description" content="When you try to mix Homestuck with The Prestige Tree together. 18 layers and very huge numbers. I'm starting to regret making this." />

	<meta name="apple-mobile-web-app-capable" content="yes">
	<link rel="apple-touch-icon" href="data/main-icon.png">

	<!-- Dependencies -->
	<link rel="stylesheet" type="text/css" href="style.css" />
	<link rel="stylesheet" type="text/css" href="popup.css" />

<!--
	<link href="https://fonts.googleapis.com/css?family=Inconsolata" rel="stylesheet">
	<link href="https://fonts.googleapis.com/css?family=Courier+Prime:wght@400;700" rel="stylesheet">
-->
	<script src="https://cdn.jsdelivr.net/npm/vue@2.6.12"></script>
	<script src="https://cdn.jsdelivr.net/npm/three@0.129.0"></script>

	<script src="js/technical/break_eternity.js"></script>
	<script src="js/init.js"></script>
	<script src="js/modal.js"></script>
	<script src="js/technical/layerSupport.js"></script>
	<script src="js/utils/save.js"></script>
	<script src="js/tree.js"></script>
	<script src="js/mod.js"></script>
	<script src="js/utils.js"></script>
	<script src="js/utils/NumberFormating.js"></script>
	<script src="js/utils/options.js"></script>
	<script src="js/utils/themes.js"></script>

	<script src="js/layers/tracker.js"></script>

	<!-- Act 0 -->
	<script src="js/layers/act0/skaia.js"></script>
	<script src="js/layers/act0/aspTime.js"></script>
	<script src="js/layers/act0/aspSpace.js"></script>
	<script src="js/layers/act0/aspHeart.js"></script>
	<script src="js/layers/act0/aspMind.js"></script>
	<script src="js/layers/act0/aspHope.js"></script>
	<script src="js/layers/act0/aspRage.js"></script>
	<script src="js/layers/act0/aspLight.js"></script>
	<script src="js/layers/act0/aspVoid.js"></script>
	<script src="js/layers/act0/aspLife.js"></script>
	<script src="js/layers/act0/aspDoom.js"></script>
	<script src="js/layers/act0/aspBreath.js"></script>
	<script src="js/layers/act0/aspBlood.js"></script>

	<script src="js/layers/act0/metaAspects.js"></script>
	<script src="js/layers/act0/metaClasses.js"></script>
	<script src="js/layers/act0/metaProspit.js"></script>
	<script src="js/layers/act0/metaDerse.js"></script>
	<script src="js/layers/act0/metaMeta.js"></script>

	<!-- Act 1 -->
	<script src="js/sburb/main.js"></script>
	<script src="js/layers/act1/players.js"></script>
	<script src="js/layers/act1/player1.js"></script>

	<script src="js/technical/temp.js"></script>
	<script src="js/technical/displays.js"></script>
	<script src="js/game.js"></script>
	<script src="js/technical/systemComponents.js"></script>
	<script src="js/components.js"></script>
	<script src="js/technical/canvas.js"></script>

</head>

<body onload="load()">
<script src="chs.js"></script>
<script src="core.js"></script>
	<div id="app">
		<canvas id="treeCanvas" class="canvas" v-if="!(gameEnded && !player.keepGoing)"></canvas>
		
		<div v-if="false" id="loadingSection" class="fullWidth" style="z-index:2147483647;position:fixed;background-color:var(--background)">
			<div>
				<h1>The Prestreestuck</h1><br />
				<h2>v0.1.1.3</h2>
			</div>
			<div>
				<h3>Loading...</h3>
				<h4>
					If you're seeing this for too long, something bad must've happened!<br />
					Try reloading the page, and if it don't help, contact the mod author!
				</h4>
			</div>
		</div>
		<div class="vl" v-if="player.navTab !== 'none' && tmp.other.splitScreen && player.tab!='none' && !(gameEnded && !player.keepGoing)"></div>

		<div v-if="VERSION.num != '0.1.1.3' || VERSION.num != gameVer || VERSION.num != compVer || VERSION.num != systemVer" class="fullWidth" style="z-index:2147483000;background-color:var(--background)">
			<br>
			<h2>The game is currently being updated.</h2><br />
			If you can see this message, that means the game has detected inconsistent version number between files.<br />
			This can be caused by the website currently being updated and not ready yet or there is an error causing the files to be read incorrectly.<br />
			Please try again later, or if this screen has been up for more than 30 minutes, please contact the mod author.<br />
			<br>
			index.js version: 0.1.1.3<br />
			mod.js version: {{VERSION.num}}<br />
			game.js version: {{gameVer}}<br />
			components.js version: {{compVer}}<br />
			systemComponents.js version: {{systemVer}}<br />
			<br>
		</div>
		<div class="vl" v-if="player.navTab !== 'none' && tmp.other.splitScreen && player.tab!='none' && !(gameEnded && !player.keepGoing)"></div>
		<div v-if="(gameEnded && !player.keepGoing)" class="fullWidth">
			<br>
			<h2>{{modInfo.name}} {{VERSION.withoutName}}</h2><br><br>
			<h3 v-html="modInfo.winText"></h3><br>
			<br>
			<h3>Please check the Discord to see if there are new content updates!</h3><br><br>
			<div v-if="!player.timePlayedReset">花了你 {{formatTime(player.timePlayed)}} 去打败游戏.</div>
			<br>
			<button class="longUpg can" onclick="hardReset(true)">Play Again</button>&nbsp;&nbsp;&nbsp;&nbsp;<button
				class="longUpg can" onclick="keepGoing()">Keep Going</button>
			<br><br><br>
			<span v-if="modInfo.discordLink"><a class="link" v-bind:href="modInfo.discordLink"
					target="_blank">{{modInfo.discordName}}</a><br></span>
			<a class="link" href="https://discord.gg/F3xveHV" target="_blank"
				v-bind:style="modInfo.discordLink ? {'font-size': '16px'} : {}">The Modding Tree Discord</a><br>
			<a class="link" href="http://discord.gg/wwQfgPa" target="_blank" v-bind:style="{'font-size': '16px'}">Main
				Prestige Tree server</a><br>
			<br><br>
		</div>

		<div id="treeOverlay" v-if="!(gameEnded && !player.keepGoing) && (player.tab === 'none' || tmp.other.splitScreen || !readData(layoutInfo.showTree))" class="treeOverlay" onscroll="resizeCanvas()"
			v-bind:class="{ 
			fullWidth: (player.tab == 'none' || player.navTab == 'none' || !readData(layoutInfo.showTree)), 
			col: (player.tab !== 'none' && player.navTab !== 'none'), 
			left: (player.tab !== 'none' && player.navTab !== 'none')}"
			 :style="{'margin-top': !readData(layoutInfo.showTree) && ['info-tab', 'changelog-tab'].includes(player.tab) ? '50px' : ''}">
			<div id="version" onclick="showTab('changelog-tab')" class="overlayThing" style="margin-right: 13px" 
				v-bind:style="{'margin-top': !readData(layoutInfo.showTree) && ['info-tab', 'changelog-tab'].includes(player.tab) ? '-50px' : ''}">
				{{VERSION.withoutName}}</div>
			<button
				v-if="player.navTab == 'none' && (tmp[player.tab].row == 'side' || tmp[player.tab].row == 'otherside')"
				class="other-back overlayThing" onclick="goBack()">←</button>
			<img id="optionWheel" class="overlayThing" v-if="player.tab!='options-tab'" src="data/options_wheel.png"
				onclick="showTab('options-tab')"></img>
			<div id="info" v-if="player.tab!='info-tab'" class="overlayThing" onclick="showTab('info-tab')"><br>i</div>
			<div id="discord" class="overlayThing">
				<img onclick="window.open((modInfo.discordLink ? modInfo.discordLink : 'https://discord.gg/F3xveHV'),'mywindow')" src="data/discord.png" target="_blank"></img>
				<ul id="discord-links">
					<li>Discord links:<br/><br/></li>
					<li v-if="modInfo.discordLink"><a class="link" v-bind:href="modInfo.discordLink"
							target="_blank">{{modInfo.discordName}}</a><br></li>
					<a class="link" href="https://discord.gg/F3xveHV" target="_blank"
							v-bind:style="modInfo.discordLink ? {'font-size': '16px'} : {}">The Modding Tree
							Discord</a><br></li>
					<li><a class="link" href="http://discord.gg/wwQfgPa" target="_blank"
							v-bind:style="{'font-size': '16px'}">Jacorb's Main Server</a></li>
				</ul>
			</div>
			<overlay-head v-if="!(gameEnded && !player.keepGoing) && layoutInfo.showTree()"></overlay-head>
			<div class="sideLayers">
				<div v-for="(node, index) in OTHER_LAYERS['side']">
					<tree-node :layer='node' :abb='tmp[node].symbol' :size="'small'" :key="'side' + index"></tree-node>
				</div>
			</div>
		</div>

		<div v-if="!(gameEnded && !player.keepGoing) && (player.tab === 'none' || tmp.other.splitScreen)" id="treeTab" style="z-index: 0" onscroll="resizeCanvas()" 
			v-bind:class="{ fullWidth: (player.tab == 'none' || player.navTab == 'none'), col: (player.tab !== 'none' && player.navTab !== 'none'), left: (player.tab !== 'none' && player.navTab !== 'none')}">
			<br><br><br><br>
			<overlay-head id="fakeHead" style="visibility: hidden;">
			</overlay-head>

			<layer-tab :layer="player.navTab == 'none' ? player.tab : player.navTab" :key="'left'"></layer-tab>

		</div>

		<!-- Popups -->
		<div class="popup-container">
			<button v-on:click="() => { activePopups.splice(0, activePopups.length) }" class="popup-close" v-bind:style="{transform: activePopups.length > 1 ? 'translateY(0px)' : 'translateY(-90px)'}">
				✕
			</button>
			<transition-group name="fade">
				<div v-for="popup,index in activePopups" class="popup" v-bind:class="popup.type"
					v-bind:key="'p' + popup.id" v-on:click="() => {activePopups.splice(index, 1)}" v-bind:style="popup.color ? {'background-color': popup.color} : {}">
					{{popup.title}}<br>
					<h3 v-html="popup.message"></h3>
				</div>
			</transition-group>
		</div>

		<!-- Modals -->
		<div v-if="modal.showing" class="modal">
			<div>
				<span v-if="modal.title"><h3 style="font-size:24px" v-html="modal.title"></h3><br/></span>
				<span v-html="modal.content"></span><br/>
				<button v-if="modal.dismiss" onclick="modal.hide()" v-html="modal.dismiss"></button>
			</div>
		</div>

		<div v-if="player.navTab !== 'none' && player.tab !== 'none' && !(gameEnded && !player.keepGoing)" onscroll="resizeCanvas()" style="background-color:var(--background)" v-bind:class="{ fullWidth: player.navTab == 'none' || !tmp.other.splitScreen || !readData(layoutInfo.showTree), col: player.navTab != 'none', right: player.navTab != 'none', fast: true, tab: true}">
			<div v-for="layer in LAYERS">
				<div v-if="player.tab==layer">
					<layer-tab :layer="layer" :back="'none'" :spacing="'50px'" :key="'left'"></layer-tab>
				</div>
			</div>
		</div>

		<!-- Debug -->
		<div class="debug">
			<span v-if="meta.options.showFPS">tick: {{format(rawDiff*1000, 0)}}ms ~ {{format(1/rawDiff)}}ps</span>
		</div>
	</div>
	
<!--客服 开始-->
<script src="//g8hh.com.cn/static/js/jquery.min.js"></script>
<link rel="stylesheet" href="//g8hh.com.cn/static/css/kf.css" type="text/css" media="screen" charset="utf-8">
<script src="//g8hh.com.cn/static/js/kf.js"></script>
<!-- 客服 结束 -->
<!--站长统计-->
<div style="display: none">
    <script>
    var _hmt = _hmt || [];
    (function() {
      var hm = document.createElement("script");
      hm.src = "https://hm.baidu.com/hm.js?dbb7ff142f4d4b68546c93b9cd6e9328";
      var s = document.getElementsByTagName("script")[0]; 
      s.parentNode.insertBefore(hm, s);
    })();
    </script>
        </div>
</body>